import{L as T}from"./LoadingBox-8_Lghccx.js";import{O as Z,a as I,b as O}from"./OnboardingPage-9CCXk6WQ.js";import{d as V,Q as k,C as u,R as A,a as p,o as a,b as N,w as i,e as c,f as e,m as t,c as l,p as C,x as L,y as R,_ as B}from"./index-c80Lh_is.js";const S=r=>(L("data-v-6c023d87"),r=r(),R(),r),D=S(()=>t("p",{class:"mb-4 text-center"},`
            A zone requires both the zone control plane and zone ingress. On Kubernetes, you run a single command to create both resources. On Universal, you must create them separately.
          `,-1)),E={class:"mb-4 text-center"},G=["href"],K={class:"status-box mt-4"},M={key:0,class:"status--is-connected","data-testid":"zone-connected"},P={key:1,class:"status--is-disconnected","data-testid":"zone-disconnected"},U={class:"status-box mt-4"},q={key:0,class:"status--is-connected","data-testid":"zone-ingress-connected"},H={key:1,class:"status--is-disconnected","data-testid":"zone-ingress-disconnected"},Q={key:0,class:"status-loading-box mt-4"},b=1e3,j=V({__name:"OnboardingMultiZoneView",setup(r){const m=k(),o=u(!1),s=u(!1),d=u(null),_=u(null);A(function(){v(),h()}),f(),g();async function f(){try{const{total:n}=await m.getZones();o.value=n>0}catch(n){o.value=!1,console.error(n)}finally{o.value||(v(),d.value=window.setTimeout(f,b))}}async function g(){try{const{total:n}=await m.getAllZoneIngressOverviews();s.value=n>0}catch(n){s.value=!1,console.error(n)}finally{s.value||(h(),_.value=window.setTimeout(g,b))}}function v(){d.value!==null&&window.clearTimeout(d.value)}function h(){_.value!==null&&window.clearTimeout(_.value)}return(n,F)=>{const y=p("RouteTitle"),x=p("AppView"),z=p("RouteView");return a(),N(z,{name:"onboarding-multi-zone-view"},{default:i(({t:w})=>[c(y,{title:w("onboarding.routes.multizone.title"),render:!1},null,8,["title"]),e(),c(x,null,{default:i(()=>[c(Z,null,{header:i(()=>[c(I,null,{title:i(()=>[e(`
              Add zones
            `)]),_:1})]),content:i(()=>[D,e(),t("p",E,[t("b",null,[e("See "),t("a",{href:w("onboarding.href.docs.install"),target:"_blank"},"the documentation for options to install",8,G),e(".")])]),e(),t("div",null,[t("p",K,[e(`
              Zone status:

              `),o.value?(a(),l("span",M,"Connected")):(a(),l("span",P,"Disconnected"))]),e(),t("p",U,[e(`
              Zone ingress status:

              `),s.value?(a(),l("span",q,"Connected")):(a(),l("span",H,"Disconnected"))]),e(),!s.value||!o.value?(a(),l("div",Q,[c(T)])):C("",!0)])]),navigation:i(()=>[c(O,{"next-step":"onboarding-create-mesh-view","previous-step":"onboarding-configuration-types-view","should-allow-next":o.value&&s.value},null,8,["should-allow-next"])]),_:2},1024)]),_:2},1024)]),_:1})}}}),Y=B(j,[["__scopeId","data-v-6c023d87"]]);export{Y as default};
